home *** CD-ROM | disk | FTP | other *** search
- ; **** Macros ****
- ;----------------------------------------------------------------------------
- ; First of all: I read somewhere into a document file that the Intel's theory
- ; about short jumps and the extra ticks caused by the next instruction's size
- ; after a normal short jump IS NOT CORRECT. I was stunned, because all this
- ; time I tried to optimize my programs according to this wrong theory... So
- ; I checked this thing out and I was stunned again: INDEED, THE THEORY IS NOT
- ; CORRECT. So I wrote this little include file here to use it in my future
- ; asm productions. So: TASM's NOPs are garbage ! They slow down the code,
- ; instead of accelerating it. The phrase with even addresses is also a shit.
- ; Don't believe what they say about this, try it by yourself and you will
- ; see w/ your own eyes they are wrong.
- ; ... btw, sjxx means : "short jump if ...xx..." :)
- ;----------------------------------------------------------------------------
- ; version 0.0000000001E-9
- ; written by Maple Leaf as an alternative for TASM's short jumps
- ;
-
- sje macro dist
- db 74h
- db dist-$-1
- endm
-
- sjne macro dist
- db 75h
- db dist-$-1
- endm
-
- sjl macro dist
- db 7Ch
- db dist-$-1
- endm
-
- sjle macro dist
- db 7Eh
- db dist-$-1
- endm
-
- sjg macro dist
- db 7Fh
- db dist-$-1
- endm
-
- sjge macro dist
- db 7Dh
- db dist-$-1
- endm
-
- sjz macro dist
- db 74h
- db dist-$-1
- endm
-
- sjnz macro dist
- db 75h
- db dist-$-1
- endm
-
- sjo macro dist
- db 70h
- db dist-$-1
- endm
-
- sjno macro dist
- db 71h
- db dist-$-1
- endm
-
- sjcxz macro dist
- db 0E3h
- db dist-$-1
- endm
-
- sja macro dist
- db 077h
- db dist-$-1
- endm
-
- sjae macro dist
- db 073h
- db dist-$-1
- endm
-
- sjb macro dist
- db 072h
- db dist-$-1
- endm
-
- sjbe macro dist
- db 076h
- db dist-$-1
- endm
-
- sjc macro dist
- db 072h
- db dist-$-1
- endm
-
- sjnc macro dist
- db 073h
- db dist-$-1
- endm
-